using System;
using System.Collections.Generic;

namespace PhillyCodeCamp.Infrastructure
{
    public class SimpleDependencyResolver : IDependencyResolver
    {

        private readonly IDictionary<Type, object> _dependencies;

        public SimpleDependencyResolver(IDictionary<Type, object> dependencies)
        {
            _dependencies = dependencies;
        }

        public T Resolve<T>()
        {
            return (T)_dependencies[typeof(T)];
        }

    }
}